﻿Public Class Movie
#Region "Variables"
    Private _ImdbID As Int64
    Private _Year As Integer
    Private _Rating As Double
    Private _Votes As Integer
    Private _Rated As String
    Private _Genres As List(Of String)
    Private _Directors As List(Of Person)
    Private _Writers As List(Of Person)
    Private _Actors As List(Of Person)
    Private _ImageURL As String
    Private _Image As Drawing.Image = Nothing
    Private _Title As String
    Private _Description As String
    Private _Runtime As String
    Private _Languages As String()
#End Region
#Region "Methods"
    Public Sub New(ByVal iCode As Long, ByVal sTitle As String, ByVal sDescription As String)
        Clean()
        ImdbID = iCode
        Title = sTitle
        Description = sDescription
    End Sub
    Public Sub New(ByVal iCode As Long, ByVal sTitle As String)
        Clean()
        ImdbID = iCode
        Title = sTitle
    End Sub
    Sub New()
        Clean()
    End Sub
    Public Sub Clean()
        ImdbID = 0
        Year = 0
        Rating = 0
        Votes = 0
        Rated = ""
        Description = ""
        Runtime = ""
        Genres = New List(Of String)()
        Directors = New List(Of Person)()
        Writers = New List(Of Person)()
        Actors = New List(Of Person)()
        ImageURL = ""
        Languages = Nothing
    End Sub
#End Region
#Region "Properties"
    Public Property ImdbID() As Long
        Get
            Return _ImdbID
        End Get
        Set(ByVal value As Long)
            _ImdbID = value
        End Set
    End Property

    Public Property Title() As String
        Get
            Return _Title
        End Get
        Set(ByVal value As String)
            _Title = value
        End Set
    End Property

    Public Property Description() As String
        Get
            Return _Description
        End Get
        Set(ByVal value As String)
            _Description = value
        End Set
    End Property

    Public Property Year() As Integer
        Get
            Return _Year
        End Get
        Set(ByVal value As Integer)
            _Year = value
        End Set
    End Property

    Public Property Actors() As List(Of Person)
        Get
            Return _Actors
        End Get
        Set(ByVal value As List(Of Person))
            _Actors = value
        End Set
    End Property

    Public Property Directors() As List(Of Person)
        Get
            Return _Directors
        End Get
        Set(ByVal value As List(Of Person))
            _Directors = value
        End Set
    End Property

    Public Property Writers() As List(Of Person)
        Get
            Return _Writers
        End Get
        Set(ByVal value As List(Of Person))
            _Writers = value
        End Set
    End Property

    Public Property Rating() As Double
        Get
            Return _Rating
        End Get
        Set(ByVal value As Double)
            _Rating = value
        End Set
    End Property

    Public Property Votes() As Integer
        Get
            Return _Votes
        End Get
        Set(ByVal value As Integer)
            _Votes = value
        End Set
    End Property

    Public Property Languages() As String()
        Get
            Return _Languages
        End Get
        Set(ByVal value As String())
            _Languages = value
        End Set
    End Property

    Public Property Genres() As List(Of String)
        Get
            Return _Genres
        End Get
        Set(ByVal value As List(Of String))
            _Genres = value
        End Set
    End Property

    Public Property Image() As Drawing.Image
        Get
            Return _Image
        End Get
        Set(ByVal value As Drawing.Image)
            _Image = value
        End Set
    End Property

    Public Property ImageURL() As String
        Get
            Return _ImageURL
        End Get
        Set(ByVal value As String)
            _ImageURL = value
        End Set
    End Property

    Public Property Rated() As String
        Get
            Return _Rated
        End Get
        Set(ByVal value As String)
            _Rated = value
        End Set
    End Property

    Public Property Runtime() As String
        Get
            Return _Runtime
        End Get
        Set(ByVal value As String)
            _Runtime = value
        End Set
    End Property

#End Region
End Class

